<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>背景位置-方位名词</title>
    <style>
        div {
            width: 600px;
            height: 400px;
            background-color: pink;
            background-image: url(../素材/icon.jpg);
            background-repeat: no-repeat;
            /* 方位名词 ,位置与顺序没有关系*/
            /* background-position: center right; */
            /* background-position: right center; */
            /* 靠右侧对齐，y轴省略，垂直居中显示 */
            /* background-position: top; */
            background-position: 20px 30px;
        }
    </style>
</head>

<body>
    <div></div>
</body>

</html>